package org.nmgyjt.springboot.controller;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import org.nmgyjt.springboot.entity.ApiRes;
import org.nmgyjt.springboot.entity.refuge.RefugeInfo;
import org.nmgyjt.springboot.service.OrganizationService;
import org.nmgyjt.springboot.service.RefugeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

@RestController
@RequestMapping("/cs/organization")
public class OrganizationController {

    @Autowired
    private OrganizationService organizationService;

    @GetMapping("/listTree")
    public ApiRes listTree() {
        return organizationService.listTree();
    }

    @GetMapping("/delRedisByKey")
    public ApiRes delRedisByKey(String key) {
        return organizationService.delRedisByKey(key);
    }

    @GetMapping("/list")
    public ApiRes listOrg(String id) {
        return organizationService.listOrg(id);
    }


}
